1. Field of the Invention
The present invention relates to an encoding apparatus and method of efficiently encoding an image and a storage medium storing the method.
2. Related Background Art
Predictive encoding is available as one conventional encoding scheme used in an encoding apparatus. In the predictive encoding, when the value of a pixel to be encoded (target pixel) is encoded, a predictive value is generated on the basis of the values of pixels around the target pixel, and the difference (prediction error) between the value of the target pixel and the prediction value is entropy-encoded.
In improved predictive encoding, a plurality of so-called prediction schemes of generating a prediction value from neighboring pixels are prepared, and these prediction schemes are adaptively used to generate an optimal prediction value, thereby entropy-encoding the difference between the prediction value and the value of the target pixel.
In the above conventional predictive encoding scheme of generating the prediction value on the basis of a plurality of neighboring pixels, no technique has been available to suppress the amount of encoded data generated by this encoding to an amount near to a predetermined amount. Furthermore, there has been room for development of an effective technique of minimizing any deterioration in the quality of the image represented by the above encoded data.